package com.vhall.component.controller.preparation;


import com.vhall.component.controller.preparation.facade.ScrollingFacade;
import com.vhall.component.entity.preparation.vo.ScrollingInfoVO;
import com.vhall.component.entity.preparation.vo.ScrollingVO;
import com.vhall.component.framework.common.annotation.VhallComponent;
import com.vhall.component.plugin.common.annotation.VssTokenAuth;
import com.vhall.component.service.preparation.ScrollingService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.validation.annotation.Validated;

/**
 * @author rui.zhou
 * @date 2021/4/28 17:08
 */

@VhallComponent
@Slf4j
@VssTokenAuth
public class ScrollingController implements ScrollingFacade {

    @Autowired
    private ScrollingService scrollingService;


    /**
     * 方便前端不报错
     *
     * @return scrollingVO
     */
    @Override
    @VssTokenAuth
    public ScrollingVO getScroll(@Validated ScrollingInfoVO vo) {
        return scrollingService.getScroll(vo.getRoomId());
    }
}
